
<!-- Container -->
<div id="container">
	<div class="shell">

		<!-- Small Nav -->
		<div class="small-nav">
			<a href="#">Dashboard</a> <span>&gt;</span> Current Shiipper
		</div>
		<?php
		$label = 'shipper';
		include 'includes/message.php';
		?>
		<br />
		<!-- Main -->
		<div id="main">
			<div class="cl">&nbsp;</div>

			<!-- Content -->
			<div id="content">


			<?php
			if($action == ''){
				?>

				<!-- Box -->
				<div class="box" style="width: 1000px">
					<!-- Box Head -->
					<div class="box-head">
						<h2 class="left">
							Current Shippers
							<h2>
								<!--
						<div class="right">
							<label>search Transaction</label>
							<input type="text" class="field small-field" />
							<input type="submit" class="button" value="search" />
						</div>
						-->
					
					</div>
					<!-- End Box Head -->

					<!-- Table -->
					<div class="table" style="width: 100%">
						<table width="100%" border="0" cellspacing="0" cellpadding="0">
							<tr>
								<th>Date Created:</th>
								<th>Name</th>
								<th>Description</th>
								<th>Created By</th>
								<th>Updated By</th>
								<th>Updated On</th>
								<th width="110" class="ac">Action</th>
							</tr>


							<?php
							if ($totalRecords > 0)
							{
								foreach ($query->result() as $shipper)
								{
									echo "
											<tr>
												<td>".$shipper->createdon."</td>
												<td>".$shipper->name."</td>
												<td>".$shipper->description."</td>
												<td>".$shipper->createdby."</td>
												<td>".$shipper->updatedby."</td>
												<td>".$shipper->updatedon."</td>
												<td><a href='".ADMINBASEURL."shipper/edit/".$shipper->id."'  class='ico edit'>edit</a> | <a href='".ADMINBASEURL."shipper/delete/".$shipper->id."'  class='ico del'>delete</a></td>
											</tr>";


								}
							}

							?>




						</table>

						<?php
						include 'includes/pagination.php';
						?>

					</div>
					<!-- Table -->

				</div>
				<!-- End Box -->

				<?php
			}else{
				?>

				<!-- Box -->
				<div class="box">
					<!-- Box Head -->
					<div class="box-head">
						<h2>
						<?php echo isset($shipper)? 'Edit' : 'Add New' ?>
							Shipper
						</h2>
					</div>
					<!-- End Box Head -->

					<form action="<?php echo ADMINBASEURL."$label/save/"; ?>"
						method="post" onsubmit="return MyForm.validate(this);">

						<!-- Form
Full Name	Username	Email	Usertype	Warehouse	Created By
						-->
						<div class="form">

						<?php
						if($action == 'edit' && isset($shipper))
						echo "<input type='hidden' name='id'  value='".$shipper->id."'>";
						?>
							<p>
								<label>Name <span>(Required Field)</span> </label> <input
									type="text" class="field size5" name="name" id="name*"
									alt="Shipper Name" maxlength="100" style="width: 300px"
									value="<?php echo isset($shipper)?$shipper->name:''; ?>" />
							</p>

							<p>
								<label>Description <span>(Required Field)</span> </label>
								<textarea name="description" class="field size3" rows="2"
									style="width: 90%" id="description*" alt="Shipper Description">
									<?php echo isset($shipper)?$shipper->description:''; ?>
								</textarea>
							</p>



						</div>
						<!-- End Form -->

						<!-- Form Buttons -->
						<div class="buttons">
							<input type="submit" class="button" value="submit" />
						</div>
						<!-- End Form Buttons -->
					</form>
				</div>
				<!-- End Box -->

				<?php
			}
			?>

			</div>
			<!-- End Content -->

			<!-- Sidebar -->
			<div id="sidebar">


				<!-- End Box -->
			</div>
			<!-- End Sidebar -->

			<div class="cl">&nbsp;</div>
		</div>
		<!-- Main -->
	</div>
</div>
<!-- End Container -->



